Skip to content

chore: standardize on modern Node and fix vue-tsc to run on it#39

Merged
gennitdev merged 1 commit into
mainfrom
chore/modernize-node-toolchain
Jun 16, 2026
Merged

chore: standardize on modern Node and fix vue-tsc to run on it#39
gennitdev merged 1 commit into
mainfrom
chore/modernize-node-toolchain

Conversation

@gennitdev

Copy link
Copy Markdown
Owner

Summary

The repo pinned three different Node versions.nvmrc (20.11.1), CI (22), and package.json engines (>=24.13.0) — and no single version could run the whole toolchain:

  • eslint 9 needs Node 21+ (Object.groupBy).
  • vue-tsc 2.2.x crashed on Node 22+ loading the vue-router volar plugin (plugin is not a function).

This standardizes everything on Node 24 and upgrades vue-tsc so the full toolchain (eslint + vue-tsc + vitest) runs green on one modern Node — and the pre-commit hook works again.

Changes

  • Upgrade vue-tsc 2.2.x → 3.3.5 (and @vue/language-core), which loads the volar plugins correctly under modern Node.
  • Remove unnecessary defineProps/defineEmits/defineExpose imports from 13 <script setup> files (vue-tsc 3 correctly flags these compiler macros as TS2440 import-conflicts; they were never needed).
  • Pin .nvmrc to 24.13.0 (matches the engines field).
  • Bump CI (unit-tests-ci.yml) from Node 22 → 24.

Verification (all on Node 24)

  • vue-tsc --noEmit: 0 errors.
  • eslint: 0 errors (295 pre-existing warnings).
  • Full vitest run: 1681 passing.
  • Committed with the pre-commit hook enabled — it passed end-to-end on Node 24.

Notes

  • One harmless non-fatal warning remains under vue-tsc 3: Resolve plugin path failed: vue-router/volar/sfc-route-blocks (that plugin only handles <route> SFC blocks). tsc still exits 0.
  • A few mock-based specs (Map.spec constructor mocks, useAlbumImageUpload window.alert) fail on Node 20 but pass on Node 24 — another reason to standardize.
  • Independent of test: increase coverage via logic extraction and shared mock helpers #38 (zero file overlap; merge in any order).

🤖 Generated with Claude Code

The repo pinned three different Node versions: .nvmrc (20.11.1), CI (22),
and package.json engines (>=24.13.0). No single version could run the whole
toolchain — eslint 9 needs Node 21+ (Object.groupBy) while vue-tsc 2.2.x
crashed on Node 22+ loading the vue-router volar plugin
("plugin is not a function").

- upgrade vue-tsc 2.2.x -> 3.3.5 (and @vue/language-core), which loads the
  volar plugins correctly under modern Node
- remove unnecessary defineProps/defineEmits/defineExpose imports from
  <script setup> (vue-tsc 3 correctly flags these compiler macros as
  TS2440 import-conflicts; they were never needed)
- pin .nvmrc to 24.13.0 to match the engines field
- bump CI (unit-tests-ci.yml) from Node 22 to 24

With these changes the full toolchain (eslint, vue-tsc, vitest) runs green
on a single modern Node, so the pre-commit hook works again.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@vercel

vercel Bot commented Jun 16, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
open-forum-frontend Ready Ready Preview, Comment Jun 16, 2026 6:44am

Request Review

@codecov-commenter

Copy link
Copy Markdown

Welcome to Codecov 🎉

Once you merge this PR into your default branch, you're all set! Codecov will compare coverage reports and display results in all future pull requests.

ℹ️ You can also turn on project coverage checks and project coverage reporting on Pull Request comment

Thanks for integrating Codecov - We've got you covered ☂️

@gennitdev gennitdev merged commit b8f0e92 into main Jun 16, 2026
3 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants